#include "common.h"

#define END_OF_FILE (EOF)

class Lexer {
private:
	char *src;
	int length;
	int index;
	char *buf;

public:
	Lexer(char *filename);
	Lexer();
	~Lexer();
	void reset();
	bool isReady();
	bool isFinished();
	char *getSrc();
	int getIndex();
	int getLength();
	void setSrc(char *s, int len);
	int findRow(char *p);
	int findCol(char *p);
	void printErorr(char *errorInfo);
	void getSingleOperator(char c, Token &token);

	Token nextToken();
};
